<!DOCTYPE >
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>Insert title here</title>
		<script type="text/javascript">
			var cityList = new Array();
			var quList = new Array();
			cityList['广东省'] = ['广州市','佛山市','深圳市','珠海市'];
			cityList['广西壮族自治区'] = ['南宁市', '柳州市', '桂林市', '北海市'];

			quList['广州市'] = ['越秀区', '花都区', '黄埔区', '天河区','海珠区'];
			quList['佛山市'] = ['禅城区', '南海区', '顺德区', '三水区','高明区'];
			quList['深圳市'] = ['罗湖区', '福田区', '南山区', '龙岗区','宝安区'];
			quList['珠海市'] = ['金湾区', '香洲区', '斗门区'];
			quList['南宁市'] = ['江南区', '兴宁区', '城北区', '新城区','永新区','马山县','武鸣县'];
			quList['柳州市'] = ['城中区', '柳北区', '柳南区', '鱼峰区','柳东区','柳江县'];
			quList['桂林市'] = ['秀峰区', '象山区', '七星区', '雁山区'];
			quList['北海市'] = ['海城区', '银海区', '铁山港区'];

			window.onload = allData;
			//省
			function allData() {
				var shengfen = document.getElementById('shengfen');
				for (var sf in cityList) {
					shengfen.add(new Option(sf, sf));
				}
			}
			//市
			function changeCity() {
				var chengshi = document.getElementById('chengshi');
				var sheng = document.getElementById('shengfen').value;
				chengshi.options.length = 1;
				for (var cs in cityList[sheng]) {
					chengshi.add(new Option(cityList[sheng][cs], cityList[sheng][cs]));
				}
			}
			//区县
			function changequ() {
				var shiqu = document.getElementById('shiqu');
				var cheng = document.getElementById('chengshi').value;
				shiqu.options.length = 1;
				for (var sh in quList[cheng]) {
					shiqu.add(new Option(quList[cheng][sh], quList[cheng][sh]));
				}
			}
			function address(){
				var size = province[shengfen].name + " " + 
					province[chengshi].name + " " + 
					province[shiqu].name + " ";
				$("#add_ress").val(ss);
			}
		</script>
	</head>
	<body>
		<br />

		<select id="shengfen" style="width:150px" onchange="changeCity()">
			<option>--选择省份--</option>
		</select>
		<select id="chengshi" style="width:110px" onchange="changequ()">
			<option>--选择城市--</option>
		</select>
		<select id="shiqu" style="width:110px">
			<option>--选择区/县--</option>
		</select>

		<button type="button" onclick="address()">确定</button>
		<br>
		您选择的是：<input type="text" id="add_ress" value="" />
	</body>
</html>
